home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 154 / 154.d81 / six pawns (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  6KB  |  184 lines

  1. 10 poke53281,10:poke53280,0:poke646,0:poke53272,31
  2. 12 dv=peek(186):ifdv<8thendv=8
  3. 20 :
  4. 30 rem  title screen
  5. 40 :
  6. 50 print"[147][176][192][192][174]   [146][176][192][192][174]   [146][176][192][192][174]    [146][176][192][192][174]   [146][176][192][192][174]   [146][176][192][192][174]";
  7. 60 print"[221]  [173][192][192][192][189]  [173][192][192][192][189]  [173][192][192][192][192][189]  [173][192][192][192][189]  [173][192][192][192][189]  [221]";
  8. 70 print"[221]      [162] [146][162]    [176][178][178][174][176][174][176][174][176][174][144]               [221]";
  9. 80 print"[173][174]        [146]    [221][221][173][189][221][221][173][219][219][189][144]              [176][189]";
  10. 90 print" [146][221]     [190] [188][146]    [173][177][178][174][221][221] [221][221][144]               [221] [146]";
  11. 100 print" [146][221]   [172][190]   [188][146][187]  [176][174][221][221][221][221][176][219][219][174][144]              [221] [146]";
  12. 110 print"[176][189]    [188]   [146][190]   [173][177][177][189][173][189][173][189][173][189][144]              [173][174]";
  13. 120 print"[221]         [146]    [176][178][178][174][176][178][178][174][176][174] [176][174][176][174][176][174][176][178][178][174][144]    [221]";
  14. 130 print"[173][174]        [146]    [221][221][221][221][221][221][221][221][221][221] [221][221][221][173][179][221][221][221][173][189][144]   [176][189]";
  15. 140 print" [146][221]   [172][190]   [188][146][187]  [221][171][177][189][221][171][179][221][221][221][221][221][221][221]  [221][173][177][178][174][144]   [221] [146]";
  16. 150 print" [146][221]  [190]       [188][146] [221][221]  [221][221][221][221][221][221][221][221][221][221][171][174][221][176][174][221][221][144]   [221] [146]";
  17. 160 print"[176][189]  [187]       [172][146] [173][189]  [173][189][173][189][173][177][177][177][189][173][189][173][189][173][177][177][189][144]   [173][174]";
  18. 170 print"[221]                                      [221]";
  19. 180 print"[173][174]     [176][178][178][174][176][174][176][174][176][178][178][174][176][178][178][174][176][178][178][174]    [162] [146][162][144]    [176][189]";
  20. 190 print" [146][221]     [221][221][173][189][221][221][221][221][221][221][173][189][221][221][173][189][221][221][173][189]       [146][144]    [221] [146]";
  21. 200 print" [146][221]     [221][221]  [221][171][179][221][221][171][192] [173][177][178][174][173][177][178][174]    [190] [188][146][144]    [221] [146]";
  22. 210 print"[176][189]     [221][221][176][174][221][221][221][221][221][221][176][174][176][174][221][221][176][174][221][221]  [172][190]   [188][146][187][144]  [173][174]";
  23. 220 print"[221]      [173][177][177][189][173][189][173][189][173][177][177][189][173][177][177][189][173][177][177][189]   [188]   [146][190][144]    [221]";
  24. 230 print"[173][174] [176][178][178][174][176][174][176][174][176][178][178][174][176][178][178][174][176][174]  [176][178][178][174]       [146][144]    [176][189]";
  25. 240 print" [146][221] [221][221][221][221][221][221][221][221][173][189][221][221][173][189][221][221][221][221]  [221][221][173][189]       [146][144]    [221] [146]";
  26. 250 print" [146][221] [221][171][177][189][221][221][221][221][176][178][177][189][176][178][177][189][221][221]  [221][171][192]   [172][190]   [188][146][187][144]  [221] [146]";
  27. 260 print"[176][189] [221][221]  [221][221][221][221][221][221][176][174][221][221][176][174][221][221][176][174][221][221][176][174] [190]       [188][146][144] [173][174]";
  28. 270 print"[221]  [173][189]  [173][177][177][189][173][177][177][189][173][177][177][189][173][177][177][189][173][177][177][189] [187]       [172][146][144]  [221]";
  29. 280 print"[221]  [176][192][192][192][174]  [176][192][192][192][174]  [176][192][192][192][192][174]  [176][192][192][192][174]  [176][192][192][192][174]  [221]";
  30. 290 print"[173][192][192][189]   [146][173][192][192][189]   [146][173][192][192][189]    [146][173][192][192][189]   [146][173][192][192][189]   [146][173][192][189][157][148][192]";
  31. 299 fori=217to242:pokei,peek(i)or128:next
  32. 300 tq=0:poke53370,0
  33. 302 tq=tq+1:geta$:ifa$=""andtq<200then302
  34. 304 poke53371,0
  35. 310 :
  36. 320 rem  instruction screen
  37. 330 :
  38. 340 print"[147][144]      [170][146][176][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][174][180]      [146]";
  39. 350 print"[176][192][192][192][192][192][192][189] [211][201][216] [208][193][215][206][211] [195][200][197][211][211] [208][213][218][218][204][197][144] [173][192][192][192][192][192][192][174]";
  40. 360 print"[144] [212]o begin,  three black pawns and three
  41. 370 [153]" white pawns are  positioned  on either
  42. 380 print" end of a one by seven gameboard grid.
  43. 390 [153]"     ortantantan=tantantan=tantantan=tantantantan=tantantan=tantantan=tantantan^
  44. 400 print"     [221][144][172] [146][187][221][144][172] [146][187][221][144][172] [146][187][221]    [221][172] [146][187][221][172] [146][187][221][172] [146][187][221]
  45. 410 [153]"     (NULL)stop* waitrnd(NULL)stop* waitrnd(NULL)stop* waitrnd(NULL)    (NULL)* waitrnd(NULL)* waitrnd(NULL)* waitrnd(NULL)
  46. 420 print"     [173][192][192][192][177][192][192][192][177][192][192][192][177][192][192][192][192][177][192][192][192][177][192][192][192][177][192][192][192][189][144]
  47. 430 [153]" (NULL)he three black pawns are permitted to
  48. 440 print" move  only to the right  and the three
  49. 450 [153]" white pawns are permitted to move only
  50. 460 print" to the left.   [208]awns may slide into an
  51. 470 [153]" adjacent  empty cell  or jump over one
  52. 480 print" adjacent pawn of opposite color into a
  53. 490 [153]" following empty cell.
  54. 500 print" [212]he goal is to exchange  the positions
  55. 510 [153]" of the six pawns  with the black pawns
  56. 520 print" ending on the right side and the white
  57. 530 [153]" pawns ending on the left side.
  58. 540 print" [208]ress any key to begin.";
  59. 542 fori=217to242:pokei,peek(i)or128:next
  60. 550 poke198,0:wait198,1:gets$:poke198,0
  61. 560 :
  62. 570 rem  gameboard screen
  63. 580 :
  64. 590 print"[147]";:poke53281,0:poke53280,10
  65. 592 dv=peek(186):ifdv<8thendv=8
  66. 600 m=0:c(0)=2:fori=1to3:c(i)=1:c(i+4)=-1:next:c(4)=0:c(8)=2
  67. 610 print"[147][158]        [176][192][174][178][176][174][174]  [176][192][174][176][192][174][176] [174][176][174][174][176][192][174]        ";
  68. 620 print"        [173][192][174][221][176][219][189]  [171][192][189][171][192][179][221][221][221][221][221][221][173][192][174]        ";
  69. 630 print"        [173][192][189][177][173][173][189]  [173]  [173] [189][173][177][189][173][173][189][173][192][189]
  70. 640 [153]" def ortantantantan=tantantantan=tantantantan=tantantantan=tantantantan=tantantantan=tantantantan^ "
  71. 650 [153]" def (NULL)1   defwait(NULL)2   defwait(NULL)3   defwait(NULL)4   defwait(NULL)5   defwait(NULL)6   defwait(NULL)7   defwait(NULL)"
  72. 660 [153]" def (NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)"
  73. 670 [153]" def (NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)    defwait(NULL)"
  74. 680 [153]" def /tantantantan>tantantantan>tantantantan>tantantantan>tantantantan>tantantantan>tantantantanexp"
  75. 690 [153]"            (NULL)ove (NULL)umber:"
  76. 700 [129]i[178]1[164]7:[153]"def                                        wait";:[130]
  77. 702 [129]i[178]217[164]242:[151]i,[194](i)[176]128:[130]
  78. 704 [151]214,17:[153]:[153]"def            (NULL)ress (NULL) to (NULL)uit
  79. 710 s$="                                       "
  80. 720 :
  81. 730 rem  sprite creation
  82. 740 :
  83. 750 s=53248:fori=0to62:readn:poke832+i,n:next
  84. 760 fori=2040to2047:pokei,13:next
  85. 770 fori=1to3:pokes+39+i,0:pokes+43+i,1:next
  86. 780 fori=3to15step2:pokes+i,92:next
  87. 790 fori=2to12step2:pokes+i,12+i*20:next
  88. 800 pokes+16,128:pokes+14,36
  89. 810 pokes+29,0:pokes+23,0:pokes+21,238
  90. 820 :
  91. 830 rem  input move color
  92. 840 :
  93. 850 m=m+1:p=1449:gosub1240:print""m
  94. 860 p=1824:gosub1240:fori=1to4:prints$:next
  95. 870 p=1834:gosub1240:print"[154][205]ove [195]olor ([194][154]/[215][154]):  [157]";:gosub1310:c$=g$
  96. 880 ifc$="w"orc$="[215]"then940
  97. 890 ifc$="b"orc$